package com.hmdp.config;

import org.redisson.Redisson;
import org.redisson.api.RedissonClient;
import org.redisson.config.Config;
import org.springframework.context.annotation.Bean;


public class RedissonConfig {
    @Bean
    public RedissonClient redissonClient(){
        //配置config
        Config config = new Config();
        config.useSingleServer().setAddress("redis://192.168.137.222:6379");
        return Redisson.create(config);
    }
}
